/*
 * @Author: 邱狮杰
 * @Date: 2021-05-15 11:30:38
 * @LastEditTime : 2021-05-18 17:52:06
 * @FilePath     : /wedding-dress-selection/src/page/selectionRecommendation/components/designList/index.tsx
 * @Description: 款式列表
 */

import { FC, MouseEvent } from 'react'
import DesignItem from './designItem'
import { Config } from './designItem'
import './index.scss'
type Props = {
  designConf: Config[]
  onProxyCheckClick: (e: MouseEvent<HTMLDivElement, globalThis.MouseEvent>, index: number) => void
}

const DesignList: FC<Props> = ({ designConf, onProxyCheckClick }) => {
  return (
    <div className='design'>
      {designConf.map((designItem, designIndex) => {
        return <DesignItem onProxyCheckClick={e => onProxyCheckClick(e, designIndex)} key={designIndex} config={designItem} />
      })}
    </div>
  )
}

export default DesignList
